Add Document Ingestion module for curated docs and web search - #48
Open
ParamThakkar123 wants to merge 19 commits into
Open
ParamThakkar123 wants to merge 19 commits into
ParamThakkar123 wants to merge 19 commits into
Conversation
Introduces a new Ingestion module that pulls documentation into a RAG index from two kinds of sources: curated docs (JuliaHealth, OMOP CDM, OHDSI, FunSQL.jl) and live web search via a pluggable provider (DuckDuckGo). Includes HTTP/S fetch with HTML-to-text cleaning, a search provider interface, and an orchestration pipeline (ingest/ingest_to_index) that feeds directly into RAGTools for indexing. New files: - src/ingestion.jl — module entry point - src/ingestion/types.jl — SourceDocument, SearchResult - src/ingestion/curated.jl — CURATED_SOURCES registry - src/ingestion/fetch.jl — fetch_url, html_to_text, fetch_curated - src/ingestion/search.jl — AbstractSearchProvider, DuckDuckGoProvider - src/ingestion/pipeline.jl — ingest, ingest_to_index - test/IngestionTest.jl — unit tests for offline logic - docs/src/ingestion.md — full user-facing documentation Dependencies added: HTTP, URIs
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #48 +/- ##
===========================================
+ Coverage 60.78% 71.66% +10.88%
===========================================
Files 4 15 +11
Lines 102 720 +618
===========================================
+ Hits 62 516 +454
- Misses 40 204 +164 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Add embedding generation and vector storage functionality with tests and documentation.
Introduces a Prompt module with: - FUNSQL system prompt and customizable PromptTemplate - Context formatting from retrieved chunks - Build prompts for LLM query construction Includes full test coverage and documentation page.
Introduces an Execution module with: - FUNSQL query execution against DuckDB via RAGTools - Result extraction, formatting, and display - End-to-end query-to-answer pipeline integration Includes tests and documentation updates.
…to response_generation
The Documentation job failed with six unresolvable `@ref` targets, from two separate causes: - `Chunk`, `HeaderChunk` and the rest of the chunking API are defined and exported by the `Ingestion` submodule but were never re-exported from `HealthLLM`, so `[`Chunk`](@ref)` in querying.md (which runs under `CurrentModule = HealthLLM`) had no binding to resolve against. Add them to the `import .Ingestion:` and `export` lists alongside the other ingestion names. - Documenter resolves `@ref`s inside a docstring in that docstring's own module. The `Prompt` docstrings reference `retrieve`, `search` and `Chunk`, none of which `Prompt` imports, so they failed as `HealthLLM.Prompt.retrieve` and friends. Qualify them with the `[`name`](@ref Module.name)` form, which keeps the rendered link text unchanged. `julia --project=docs docs/make.jl` now completes CrossReferences and RenderDocument with no errors. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RYi1NAjjGQ848cUMLEbh1x
feat: add Execution module for FUNSQL query execution and answer generation
feat: add Prompt module for grounded RAG query construction
feat: add retrieve() convenience method for text-query-to-search
Add embedding and storage modules
Add document chunking strategies with provenance tracking
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a new
HealthLLM.Ingestionmodule for pulling documentation into a RAG index from curated sources (JuliaHealth, OMOP CDM, OHDSI, FunSQL.jl) and live web search via a pluggable provider (DuckDuckGo).New files
src/ingestion.jl— module entry pointsrc/ingestion/types.jl— SourceDocument, SearchResult typessrc/ingestion/curated.jl— CURATED_SOURCES registrysrc/ingestion/fetch.jl— fetch_url, html_to_text, fetch_curatedsrc/ingestion/search.jl— AbstractSearchProvider, DuckDuckGoProvidersrc/ingestion/pipeline.jl— ingest, ingest_to_index orchestrationtest/IngestionTest.jl— offline unit testsdocs/src/ingestion.md— full documentationDependencies added
Modified files